import request from '@/utils/request'
export interface categoryParamsData{
    subCategoryId:number
    categoryId:number
}
interface setCategoryParamsData{
    YXJSONArray:{},
    global:{},
    data:{},
    YXJSONObject:{}
}
export default{
    // 分类页数据
    getCategory(categoryParams:categoryParamsData){
        return request.get<any,setCategoryParamsData>('/item/cateList.json',categoryParams)
    },
    getCategoryItem(categoryId:number = 11){
        return request.get(`/item/cateList.json?__timestamp=1630131455012&categoryId=${categoryId}`)
    },
    //分类下的列表
    getCategoryList(category1Id:number,category2Id:number){
        return request.get(`/item/list.json?__timestamp=1630133942864&categoryType=0&subCategoryId=${category2Id}&categoryId=${category1Id}`)
    }
}